package com.chinasoft.order.service.impl.impl;

import com.chinasoft.order.domain.Order;
import com.chinasoft.order.mapper.OrderMapper;
import com.chinasoft.order.service.impl.OrderService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.Date;
import java.util.List;

@Service("orderServiceImpl")
public class OrderServiceImpl implements OrderService {

    @Resource
    private OrderMapper orderMapper;

    @Override
    public List<Order> findAll() {
        return orderMapper.findAll();
    }

    @Override
    public int takeOrder(String rid, Integer id) {
        return orderMapper.takeOrder(rid,id);
    }

    @Override
    public int doneOrder(String id, Date arriveTime) {
        return orderMapper.doneOrder(id,arriveTime);
    }
}
